//
//  SFAccountsViewController.h
//  Sofia
//
//  Created by Anton Chebotaev on 24/11/08.
//  Copyright 2008 IFMO. All rights reserved.
//

#import <Cocoa/Cocoa.h>
#import <LJKit/LJKit.h>
#import "MBPreferencesController.h"
#import "SFStandartHeader.h"

@class SFUserAccount;
@class SFMusicFormatToken;

@interface SFAccountsViewController : NSViewController <MBPreferencesModule> {

	IBOutlet NSTextField *loginField;
	IBOutlet NSTextField *passwordField;
	IBOutlet NSArrayController *userAccountsController;
	IBOutlet NSPanel *accountDialog;
	IBOutlet NSButtonCell *defaultButton;
	
	int defaultAccountNumber;
	NSMutableArray *userAccounts;	

}
- (NSString *)identifier;
- (NSImage *)image;

// Accounts Dialog
- (IBAction)showAccountDialog:(id)sender;
- (IBAction)hideAccountDialog:(id)sender;

// User Acounts
- (IBAction)addSFUserAccount:(id)sender;
- (IBAction)removeSFUserAccount:(id)sender;
- (NSMutableArray *)loadSFUserAccounts;
- (IBAction)saveSFUserAccounts:(id)sender;

// Default Account Number
@property(readwrite, assign) int defaultAccountNumber;
- (IBAction)saveDefaultAccountNumber:(id)sender;
- (int)loadDefaultAccountNumber;


@end
